﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using TTSModel;
using TTSBLL;

public partial class checkForForeigners_AssembleTestingSummary : System.Web.UI.Page
{
    private string tcode 
    { 
        get 
        { 
            return ViewState["id"].ToString(); 
        } 
        set 
        { 
            ViewState["id"] = value; 
        }
    }


     private T0001996Summary SingleAssembleSummaryBLL;
     private IList<T0001996SummaryInfo> SingleAssembleSummaryList;

     public checkForForeigners_AssembleTestingSummary()
     {
         SingleAssembleSummaryBLL = new T0001996Summary();
     }
      protected void Page_Load(object sender, EventArgs e)
       {
          if (!IsPostBack)
           {
              // tcode = this.SNInputing.Text.Trim();               
               if (!string.IsNullOrEmpty(Request.QueryString["SN"]))
               {
                   tcode = Request.QueryString["SN"].ToString();
                   BindData();
               }
           }
           this.SNInputing.Focus();
       }


      protected void butSu_Click1(object sender, EventArgs e)
    {
        tcode = this.SNInputing.Text.Trim();
        BindData();
    }
    
  
    protected void BindData()
    {
        SingleAssembleSummaryList = SingleAssembleSummaryBLL.LoadEntities(tcode);
        this.GridView1.DataSource = SingleAssembleSummaryList;
        this.GridView1.DataBind();
    }
    protected void Button1_Click(object sender, EventArgs e)
    {
        Response.Redirect("~/search/searchMainHtml.aspx");
    }
}